package com.work.bookstore.mapper;

import com.work.bookstore.pojo.ShoppingCar;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

/**
 * @author ppg007
 * @date 2021/1/1 18:02
 */
@Mapper
@Repository
public interface ShoppingCarMapper {

    /**
     * 获取指定用户购物车
     * @param account 账号
     * @return 购物车对象
     */
    ShoppingCar queryShoppingCarByAccount(String account);


    /**
     * 修改购物车
     * @param bookList 新购物车
     * @param account 账号
     */
    void updateShoppingCar(String bookList,String account);

    /**
     * 创建购物车
     * @param bookList 书单
     * @param account 账号
     */
    void createShoppingCar(String bookList,String account);
}
